<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
let urlStr = "http://www.inode.club?name=koala&study=js&study=node";


function getUrlParams(url) {
    const params = {};
    const queryString = url.split('?')[1];

    if (queryString) {
        const pairs = queryString.split('&');
        pairs.forEach(pair => {
            const [key, value] = pair.split('=');
            if (key) {
                if (params[key]) {
                    if (!Array.isArray(params[key])) {
                        params[key] = [params[key]];
                    }
                    params[key].push(decodeURIComponent(value));
                } else {
                    params[key] = decodeURIComponent(value);
                }
            }
        });
    }
    return params;
}


const paramsObject = getUrlParams(urlStr);
console.log(paramsObject);

    </script>
</body>
</html>